/*
 Navicat Premium Data Transfer

 Source Server         : localhost
 Source Server Type    : MySQL
 Source Server Version : 100428 (10.4.28-MariaDB)
 Source Host           : localhost:3306
 Source Schema         : ledger_db

 Target Server Type    : MySQL
 Target Server Version : 100428 (10.4.28-MariaDB)
 File Encoding         : 65001

 Date: 03/07/2025 22:36:19
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for ledger_records
-- ----------------------------
DROP TABLE IF EXISTS `ledger_records`;
CREATE TABLE `ledger_records` (
  `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT '记录ID',
  `user_id` bigint(20) NOT NULL,
  `ledger_id` bigint(20) NOT NULL COMMENT '所属台账ID',
  `created_at` datetime DEFAULT current_timestamp() COMMENT '创建时间',
  `updated_at` datetime DEFAULT current_timestamp() ON UPDATE current_timestamp() COMMENT '更新时间',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=106 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;

-- ----------------------------
-- Records of ledger_records
-- ----------------------------
BEGIN;
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (3, 2, 1, '2025-07-01 12:02:00', '2025-07-02 19:14:48');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (4, 9, 1, '2025-07-01 12:03:00', '2025-07-02 19:16:18');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (5, 3, 1, '2025-07-01 12:04:00', '2025-07-02 19:14:51');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (6, 10, 1, '2025-07-01 12:05:00', '2025-07-02 19:16:22');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (7, 7, 1, '2025-07-01 12:06:00', '2025-07-02 19:16:27');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (8, 5, 1, '2025-07-01 12:07:00', '2025-07-02 19:15:59');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (9, 2, 1, '2025-07-01 12:08:00', '2025-07-02 19:16:30');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (10, 8, 1, '2025-07-01 12:09:00', '2025-07-02 19:16:33');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (11, 5, 2, '2025-07-01 12:00:00', '2025-07-02 19:16:03');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (12, 1, 2, '2025-07-01 12:01:00', '2025-07-01 12:01:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (13, 1, 2, '2025-07-01 12:02:00', '2025-07-01 12:02:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (14, 1, 2, '2025-07-01 12:03:00', '2025-07-01 12:03:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (15, 1, 2, '2025-07-01 12:04:00', '2025-07-01 12:04:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (16, 1, 2, '2025-07-01 12:05:00', '2025-07-01 12:05:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (17, 1, 2, '2025-07-01 12:06:00', '2025-07-01 12:06:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (18, 1, 2, '2025-07-01 12:07:00', '2025-07-01 12:07:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (19, 5, 2, '2025-07-01 12:08:00', '2025-07-02 19:16:06');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (20, 1, 2, '2025-07-01 12:09:00', '2025-07-01 12:09:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (21, 1, 3, '2025-07-01 12:00:00', '2025-07-01 12:00:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (22, 1, 3, '2025-07-01 12:01:00', '2025-07-01 12:01:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (23, 5, 3, '2025-07-01 12:02:00', '2025-07-02 19:16:08');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (24, 1, 3, '2025-07-01 12:03:00', '2025-07-01 12:03:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (25, 1, 3, '2025-07-01 12:04:00', '2025-07-01 12:04:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (26, 1, 3, '2025-07-01 12:05:00', '2025-07-01 12:05:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (27, 1, 3, '2025-07-01 12:06:00', '2025-07-01 12:06:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (28, 1, 3, '2025-07-01 12:07:00', '2025-07-01 12:07:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (29, 5, 3, '2025-07-01 12:08:00', '2025-07-02 19:16:11');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (30, 1, 3, '2025-07-01 12:09:00', '2025-07-01 12:09:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (31, 1, 4, '2025-07-01 12:00:00', '2025-07-01 12:00:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (32, 8, 4, '2025-07-01 12:01:00', '2025-07-02 19:16:16');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (33, 1, 4, '2025-07-01 12:02:00', '2025-07-01 12:02:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (34, 1, 4, '2025-07-01 12:03:00', '2025-07-01 12:03:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (35, 1, 4, '2025-07-01 12:04:00', '2025-07-01 12:04:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (36, 1, 4, '2025-07-01 12:05:00', '2025-07-01 12:05:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (37, 1, 4, '2025-07-01 12:06:00', '2025-07-01 12:06:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (38, 1, 4, '2025-07-01 12:07:00', '2025-07-01 12:07:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (39, 1, 4, '2025-07-01 12:08:00', '2025-07-01 12:08:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (40, 1, 4, '2025-07-01 12:09:00', '2025-07-01 12:09:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (41, 1, 5, '2025-07-01 12:00:00', '2025-07-01 12:00:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (42, 1, 5, '2025-07-01 12:01:00', '2025-07-01 12:01:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (43, 1, 5, '2025-07-01 12:02:00', '2025-07-01 12:02:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (44, 8, 5, '2025-07-01 12:03:00', '2025-07-02 19:15:34');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (45, 1, 5, '2025-07-01 12:04:00', '2025-07-01 12:04:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (46, 1, 5, '2025-07-01 12:05:00', '2025-07-01 12:05:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (47, 1, 5, '2025-07-01 12:06:00', '2025-07-01 12:06:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (48, 8, 5, '2025-07-01 12:07:00', '2025-07-02 19:15:32');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (49, 1, 5, '2025-07-01 12:08:00', '2025-07-01 12:08:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (50, 1, 5, '2025-07-01 12:09:00', '2025-07-01 12:09:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (54, 1, 6, '2025-07-01 12:03:00', '2025-07-01 12:03:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (55, 1, 6, '2025-07-01 12:04:00', '2025-07-01 12:04:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (56, 1, 6, '2025-07-01 12:05:00', '2025-07-01 12:05:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (57, 1, 6, '2025-07-01 12:06:00', '2025-07-01 12:06:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (58, 6, 6, '2025-07-01 12:07:00', '2025-07-02 19:15:25');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (59, 1, 6, '2025-07-01 12:08:00', '2025-07-01 12:08:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (60, 1, 6, '2025-07-01 12:09:00', '2025-07-01 12:09:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (61, 1, 7, '2025-07-01 12:00:00', '2025-07-01 12:00:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (62, 1, 7, '2025-07-01 12:01:00', '2025-07-01 12:01:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (63, 6, 7, '2025-07-01 12:02:00', '2025-07-02 19:15:23');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (64, 1, 7, '2025-07-01 12:03:00', '2025-07-01 12:03:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (65, 1, 7, '2025-07-01 12:04:00', '2025-07-01 12:04:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (66, 1, 7, '2025-07-01 12:05:00', '2025-07-01 12:05:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (67, 5, 7, '2025-07-01 12:06:00', '2025-07-02 19:15:20');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (68, 1, 7, '2025-07-01 12:07:00', '2025-07-01 12:07:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (69, 1, 7, '2025-07-01 12:08:00', '2025-07-01 12:08:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (70, 1, 7, '2025-07-01 12:09:00', '2025-07-01 12:09:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (71, 1, 8, '2025-07-01 12:00:00', '2025-07-01 12:00:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (72, 1, 8, '2025-07-01 12:01:00', '2025-07-01 12:01:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (73, 1, 8, '2025-07-01 12:02:00', '2025-07-01 12:02:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (74, 1, 8, '2025-07-01 12:03:00', '2025-07-01 12:03:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (75, 3, 8, '2025-07-01 12:04:00', '2025-07-02 19:15:18');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (76, 1, 8, '2025-07-01 12:05:00', '2025-07-01 12:05:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (77, 1, 8, '2025-07-01 12:06:00', '2025-07-01 12:06:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (78, 1, 8, '2025-07-01 12:07:00', '2025-07-01 12:07:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (79, 1, 8, '2025-07-01 12:08:00', '2025-07-01 12:08:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (80, 1, 8, '2025-07-01 12:09:00', '2025-07-01 12:09:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (81, 1, 9, '2025-07-01 12:00:00', '2025-07-01 12:00:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (82, 5, 9, '2025-07-01 12:01:00', '2025-07-02 19:15:04');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (83, 1, 9, '2025-07-01 12:02:00', '2025-07-01 12:02:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (84, 1, 9, '2025-07-01 12:03:00', '2025-07-01 12:03:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (85, 1, 9, '2025-07-01 12:04:00', '2025-07-01 12:04:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (86, 6, 9, '2025-07-01 12:05:00', '2025-07-02 19:15:07');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (87, 1, 9, '2025-07-01 12:06:00', '2025-07-01 12:06:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (88, 3, 9, '2025-07-01 12:07:00', '2025-07-02 19:15:09');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (89, 1, 9, '2025-07-01 12:08:00', '2025-07-01 12:08:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (90, 4, 9, '2025-07-01 12:09:00', '2025-07-02 19:15:01');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (91, 1, 10, '2025-07-01 12:00:00', '2025-07-01 12:00:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (92, 1, 10, '2025-07-01 12:01:00', '2025-07-01 12:01:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (93, 3, 10, '2025-07-01 12:02:00', '2025-07-02 19:15:12');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (94, 1, 10, '2025-07-01 12:03:00', '2025-07-01 12:03:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (95, 3, 10, '2025-07-01 12:04:00', '2025-07-02 19:15:15');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (96, 1, 10, '2025-07-01 12:05:00', '2025-07-01 12:05:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (97, 1, 10, '2025-07-01 12:06:00', '2025-07-01 12:06:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (98, 1, 10, '2025-07-01 12:07:00', '2025-07-01 12:07:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (99, 1, 10, '2025-07-01 12:08:00', '2025-07-01 12:08:00');
INSERT INTO `ledger_records` (`id`, `user_id`, `ledger_id`, `created_at`, `updated_at`) VALUES (100, 4, 10, '2025-07-01 12:09:00', '2025-07-02 19:14:58');
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
